import { getDistance } from 'ol/sphere'

export function diffDistance(start, end)  {
  const length = getDistance(start, end)
  return length < 1000 ? Math.round(length) + '米' : Math.round(length / 1000) + '公里'
}